File: IHubContext`T.cs
Web Access
Project: src\src\SignalR\server\Core\src\Microsoft.AspNetCore.SignalR.Core.csproj (Microsoft.AspNetCore.SignalR.Core)
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
 
namespace Microsoft.AspNetCore.SignalR;
 
/// <summary>
/// A context abstraction for a hub.
/// </summary>
public interface IHubContext<THub, T>
    where THub : Hub<T>
    where T : class
{
    /// <summary>
    /// Gets a <see cref="IHubClients{T}"/> that can be used to invoke methods on clients connected to the hub.
    /// </summary>
    IHubClients<T> Clients { get; }
 
    /// <summary>
    /// Gets a <see cref="IGroupManager"/> that can be used to add and remove connections to named groups.
    /// </summary>
    IGroupManager Groups { get; }
}